<html>
<head>
    <title>Smart Home</title>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <link rel="shortcut icon" href="favicon.ico" type="image/x-icon"/>
    <link rel="stylesheet" type="text/css" href="css/style.css"/>

    <script type="text/javascript" src="js/jquery.min.js"></script>
    <script type="text/javascript" src="js/websocket.js"></script>
    <script type="text/javascript" src="js/FileSaver.js"></script>

</head>
<script type="text/javascript">
    jQuery(document).ready(function ($) {
        // dashboard.init(document.location.href);
        //alert(document.location.hostname);
        ip = document.location.hostname;
        port = "8125";

        // location.host           //主机加端口号
        // location.hostname       //主机
        // location.port           //端口号
        // location.protocol       //协议
        // location.pathname       //路径
        // location.hash           //片段标识符，可以用于保存网页状态
        // location.search         //返回问号后的字段
    });
</script>

<body onload="load()">

<div id="login">
    <div>
        <input id="btnClear" type="button" value="清空日志" onclick="clearLog()"/>
        <input id="post1" type="button" value="保存日志" onclick="saveLog(getText())"/>
        <!--<input id="stoptest" type="button" value="停止测试" onclick="stopTest()"/>
        <input type="button" value="停止" onclick="stop()"/>-->
    </div>


    <div class="divcss5">
        <div  id="status">
            来自服务端的消息
        </div>
        <textarea id="txtContent" readonly="readonly" class="comments"></textarea>
    </div>
</div>
</body>

</html>